/**
 * API主路由
 */
const express = require('express');
const router = express.Router();

// 引入API版本路由
const v1Routes = require('./v1');

// 设置API版本路由
router.use('/v1', v1Routes);

// API根路径
router.get('/', (req, res) => {
  res.json({
    message: 'Next.js 演示API',
    versions: [
      '/api/v1'
    ]
  });
});

module.exports = router; 